<!DOCTYPE html>
<html>
  <head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
    <title>消息添加</title>
    <script>document.write('<script src=' + Math.random() + '"../import.js?"><' + '/script>');</script>
    <script>_import("../../../../plugin/vue/js/before.js");</script>

<style>
.c-sel-tree {
  width: 100px;
}
.c-sel-tree .vue-treeselect__multi-value {
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;  
}
</style>
  </head>
  <body>
    <div id="app">
      <!--  
      <treeselect v-model="value" class="c-sel-tree" :multiple="true" :autoSelectDescendants="true" :options="options"  />
      -->
      <treeselect :multiple="true" class="c-sel-tree1" :options="options" value-consists-of="LEAF_PRIORITY"  v-model="value"/>
    </div>
	<script>
	//_import("../../../../plugin/vue/js/after.js?type=0");	
	_import("../../../../plugin/vue/js/after.js");	
    </script>	
	<script>_import("../../../../plugin/vue/js/treeselect/vue-treeselect.js");</script>		
    <script>
        new Vue({
          el: '#app',
          data: {
            // define the default value
            value: null,
            // define options
            options: [ {
              id: 'a',
              label: 'a',
              isDefaultExpanded:true,  // 是否默认展开
              children: [ {
                id: 'aa',
                label: 'aa👱',
                isDisabled:true			//禁用
              }, {
                id: 'ab',
                label: 'ab👱',
              },{
                  id: 'ac',
                  label: 'ac🧔',
                },
              ],
            }, {
              id: 'b',
              label: 'b👥',
            }, {
              id: 'c',
              label: 'c👥',
            } ],
          },
          mounted: function () {
        	  
               this.options=this.getDeptUserOpts(0);
               console.log(this.options);
        	  },
          methods: {
        	  getDeptUserOpts:function(id){
        	    	
        	    	var reqData = {
        					"id" : id,        					
        				          };
        	
        	    	url="../../../../pub/userInfo/deptUserTreeEx.mvc";        	    	
        			data = tools.ajaxRequest(url,reqData);    
        			console.log(data);
        	    	return data.tree;;
        	    
        	    },
          }
        })
      </script>
  </body>
</html>                  